home *** CD-ROM | disk | FTP | other *** search
/ Aminet 52 / Aminet 52 (2002)(GTI - Schatztruhe)[!][Dec 2002].iso / Aminet / util / moni / Scout-src.lha / netinclude / rpc / pmap_prot.h < prev    next >
C/C++ Source or Header  |  2002-09-16  |  2KB  |  78 lines

  1. #ifndef RPC_PMAP_PROT_H
  2. #define RPC_PMAP_PROT_H
  3. /*
  4.  * $Id: pmap_prot.h,v 1.1.1.1 2001/11/26 22:21:19 tboeckel Exp $
  5.  *
  6.  * Protocol for the local binder service, or pmap.
  7.  *
  8.  * Copyright © 1994 AmiTCP/IP Group,
  9.  *                  Network Solutions Development Inc.
  10.  *                  All rights reserved.
  11.  *
  12.  */
  13. /* @(#)pmap_prot.h    2.1 88/07/29 4.0 RPCSRC; from 1.14 88/02/08 SMI */
  14.  
  15. /*
  16.  * Copyright (C) 1984, Sun Microsystems, Inc.
  17.  *
  18.  * The following procedures are supported by the protocol:
  19.  *
  20.  * PMAPPROC_NULL() returns ()
  21.  *     takes nothing, returns nothing
  22.  *
  23.  * PMAPPROC_SET(struct pmap) returns (bool_t)
  24.  *     TRUE is success, FALSE is failure.  Registers the tuple
  25.  *    [prog, vers, prot, port].
  26.  *
  27.  * PMAPPROC_UNSET(struct pmap) returns (bool_t)
  28.  *    TRUE is success, FALSE is failure.  Un-registers pair
  29.  *    [prog, vers].  prot and port are ignored.
  30.  *
  31.  * PMAPPROC_GETPORT(struct pmap) returns (long unsigned).
  32.  *    0 is failure.  Otherwise returns the port number where the pair
  33.  *    [prog, vers] is registered.  It may lie!
  34.  *
  35.  * PMAPPROC_DUMP() RETURNS (struct pmaplist *)
  36.  *
  37.  * PMAPPROC_CALLIT(unsigned, unsigned, unsigned, string<>)
  38.  *     RETURNS (port, string<>);
  39.  * usage: encapsulatedresults = PMAPPROC_CALLIT(prog, vers, proc, encapsulatedargs);
  40.  *     Calls the procedure on the local machine.  If it is not registered,
  41.  *    this procedure is quite; ie it does not return error information!!!
  42.  *    This procedure only is supported on rpc/udp and calls via
  43.  *    rpc/udp.  This routine only passes null authentication parameters.
  44.  *    This file has no interface to xdr routines for PMAPPROC_CALLIT.
  45.  *
  46.  * The service supports remote procedure calls on udp/ip or tcp/ip socket 111.
  47.  */
  48.  
  49. #define PMAPPORT        ((u_short)111)
  50. #define PMAPPROG        ((u_long)100000)
  51. #define PMAPVERS        ((u_long)2)
  52. #define PMAPVERS_PROTO        ((u_long)2)
  53. #define PMAPVERS_ORIG        ((u_long)1)
  54. #define PMAPPROC_NULL        ((u_long)0)
  55. #define PMAPPROC_SET        ((u_long)1)
  56. #define PMAPPROC_UNSET        ((u_long)2)
  57. #define PMAPPROC_GETPORT    ((u_long)3)
  58. #define PMAPPROC_DUMP        ((u_long)4)
  59. #define PMAPPROC_CALLIT        ((u_long)5)
  60.  
  61. struct pmap {
  62.     long unsigned pm_prog;
  63.     long unsigned pm_vers;
  64.     long unsigned pm_prot;
  65.     long unsigned pm_port;
  66. };
  67.  
  68. extern bool_t XDRFUN xdr_pmap(XDR * xdrs, struct pmap * regs);
  69.  
  70. struct pmaplist {
  71.     struct pmap    pml_map;
  72.     struct pmaplist *pml_next;
  73. };
  74.  
  75. extern bool_t XDRFUN xdr_pmaplist(XDR * xdrs, struct pmaplist ** rp);
  76.  
  77. #endif /* !RPC_PMAP_PROT_H */
  78.